home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Floppyshop 2
/
Floppyshop - 2.zip
/
Floppyshop - 2.iso
/
art&graf.ix
/
art-0039
/
source
/
dcqscrn.asm
< prev
next >
Wrap
Assembly Source File
|
1997-04-16
|
1KB
|
60 lines
;
;
MODULE DCQScrn
;
SYMBOLS
;
nmedy EQU 200 ;total number of med-res lines
medresll EQU 40 ;number of pixel groups
hiresll EQU 80; hi-res line length
label HiToMedRes
; Register usage: D0 ==> med res line pixel group count
; D1 ==> med res line to process count
; A0 ==> return address
; A1 ==> hi-res line 1 ptr
; A2 ==> hi-res line 2 ptr
; A4 ==> med-res line ptr
Start: ;
move.l (a7)+,a0 ;return address
move.l (a7)+,a4 ;med res screen addr
move.l (a7)+,a1 ;hi res screen addr
move.l a1,a2 ;
add.l #hiresll,a2 ;hi-res line 2 addr
;
move.w #nmedy,d1 ;mno of med-res lines do
bra.s .0nextline
.0lineloop:
move.w #medresll,d0 ;no of 16pixels
bra.s .1lnext
.1loop:
move.w (a1)+,(a4)+
move.w (a2)+,(a4)+
.1lnext:
dbra.s d0,.1loop
;
add.l #hiresll,a1
add.l #hiresll,a2 ;next pair of lines
.0nextline:
dbra.s d1,.0lineloop
jmp (a0)
;--------------------------------------------------------------------
; set all bits off in a hi-res screen
label ClearScreen
move.l (a7)+,a0
move.w #8000,d0 ;number of longwords to clear
move.l (a7)+,a1 ;addr of hi-res screen
move.l #0,d1
bra.s .0nextloop
.0loop:
move.l d1,(a1)+
.0nextloop:
dbra.s d0,.0loop
jmp (a0)
end